﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="main_notice.aspx.cs" Inherits="WorkOrder.main_notice" %>

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
    Namespace="System.Web.UI" TagPrefix="asp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <link href="./css/site2.css" type="text/css" rel="STYLESHEET" />
    <link href="./css/left.css" type="text/css" rel="STYLESHEET" />
   <script language="javascript" type="text/javascript">       //加在head中，PNG无灰色背景
       var tmp = window.navigator.userAgent.toLowerCase().indexOf("MSIE");
       //加在head中，PNG无灰色背景
       function correctPNG() {
           for (var i = 0; i < document.images.length; i++) {
               var img = document.images[i];
               var imgName = img.src.toUpperCase();
               if (imgName.substring(imgName.length - 3, imgName.length) == "PNG") {
                   var imgID = (img.id) ? "id='" + img.id + "' " : "";
                   var imgClass = (img.className) ? "class='" + img.className + "' " : "";
                   var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' ";
                   var imgStyle = "display:inline-block;" + img.style.cssText;
                   if (img.align == "left") imgStyle = "float:left;" + imgStyle;
                   if (img.align == "right") imgStyle = "float:right;" + imgStyle;
                   if (tmp >= 1) {
                       if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle;
                   }
                   else {
                       if (img.parentNode.href) imgStyle = "cursor:hand;" + imgStyle;
                   }
                   var strNewHTML = "<span " + imgID + imgClass + imgTitle + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
       + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader" + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>";
                   img.outerHTML = strNewHTML;

               }
           }
       }

       if (window.addEventListener) {
           window.addEventListener('DOMContentLoaded', correctPNG, false);   //firefox
           window.addEventListener('load', correctPNG, false);
       } else if (window.attachEvent) {
           window.attachEvent('onload', correctPNG);  //IE
       }
    </script>
</head>
<body style="margin: 0 0 0 0; background-color: #fff; border-left: solid 0px #d4f1f9;">
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
    </telerik:RadScriptManager>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="Timer1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="DataList1" UpdatePanelHeight="" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
    <asp:Timer ID="Timer1" runat="server" Interval="900000" OnTick="Timer1_Tick">
    </asp:Timer>
    <div style="border: solid 1px #9fd6ff; background-color: #d4f1f9; border-bottom: none;">
        <table style="width: 100%">
            <tr>
                <td style="height: 20px;">
                    &nbsp;&nbsp;<a href="#" onclick='parent.location="Notice/Notice.aspx"'><img alt="" align="absmiddle" src="./images/Chat2.png"
                        style="border: none" height="15" />&nbsp;系统公告</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a
                            href="#" onclick='parent.location="Notice/Notice.aspx"'>更多...</a>
                </td>
            </tr>
        </table>
    </div>
    <div id="div6" style="border: solid 1px #9fd6ff; background-color: #f0f8ff; 
        overflow: auto">
        <asp:DataList ID="DataList1" runat="server">
            <ItemTemplate>
                <div>
                    <table>
                        <tr>
                            <td style="font-family: Arial;">
                                <img align="absmiddle" src="./images/comment_blue.gif" />&nbsp;<a href="#" title="点击查看公告内容"
                                    onclick="window.open('./Notice/ShowNotice.aspx?id=<%# Eval("NoticeID") %>','','location=no,menubar=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,width=1050,height=600');">【<%# Eval("TypeName")%>】&nbsp;<%# Eval("Title")%>&nbsp;&nbsp;[<%# Eval("AuthorrName")%>]&nbsp;[<%# Eval("CreateDate")%>]</a>
                            </td>
                        </tr>
                    </table>
                </div>
            </ItemTemplate>
        </asp:DataList>
    </div>
    <script type="text/javascript">
        document.getElementById("div6").style.height = document.body.clientHeight-30;
    </script>
    </form>
</body>
</html>
